package com.ssy.lingxi.settle.accounts.model.vo.request;

import javax.validation.Valid;
import javax.validation.constraints.*;
import java.io.Serializable;
import java.math.BigDecimal;
import java.util.List;

/**
 * 新增对账单VO
 * @author Saske
 * @date 2021/12/10
 * @version 2.0.0
 */
public class ReconciliationUpdateVo implements Serializable {

    private static final long serialVersionUID = -8887960826739570028L;

    /**
     * 对账单ID
     */
    @NotNull(message = "对账单ID要大于0")
    @Positive(message = "对账单ID要大于0")
        private Long reconciliationId;

    /**
     * 对账单号
     */
    @NotBlank(message = "对账单号不能为空")
    private String reconciliationNo;


    /**
     * 对账单摘要 最长60个字符
     */
    @NotBlank(message = "对账单摘要不能为空")
    @Size(max = 60, message = "对账单摘要最长60个字符")
    private String reconciliationAbstract;


    /**
     * 待对账金额（含税）要大于等于0
     */
    @NotNull(message = "待对账金额（含税）要大于等于0")
    @PositiveOrZero(message = "待对账金额（含税）要大于等于0")
    private BigDecimal reconciliationMoneyAmount;

    /**
     * 备注 最多120个字符
     */
    @Size(max = 120, message = "备注最多120个字符")
    private String remark;

    /**
     * 账单明细附件
     */
    private List<ReconciliationFileSaveVo> files;

    /**
     * 待新增对账单行明细
     */
    @Valid
    @NotNull(message = "待新增对账单行明细不能为空")
    @Size(min = 1, message = "至少有一个待新增对账单行明细")
    private List<ReconciliationRowSaveVO> rows;

    public Long getReconciliationId() {
        return reconciliationId;
    }

    public void setReconciliationId(Long reconciliationId) {
        this.reconciliationId = reconciliationId;
    }

    public String getReconciliationNo() {
        return reconciliationNo;
    }

    public void setReconciliationNo(String reconciliationNo) {
        this.reconciliationNo = reconciliationNo;
    }

    public String getReconciliationAbstract() {
        return reconciliationAbstract;
    }

    public void setReconciliationAbstract(String reconciliationAbstract) {
        this.reconciliationAbstract = reconciliationAbstract;
    }

    public BigDecimal getReconciliationMoneyAmount() {
        return reconciliationMoneyAmount;
    }

    public void setReconciliationMoneyAmount(BigDecimal reconciliationMoneyAmount) {
        this.reconciliationMoneyAmount = reconciliationMoneyAmount;
    }

    public String getRemark() {
        return remark;
    }

    public void setRemark(String remark) {
        this.remark = remark;
    }

    public List<ReconciliationFileSaveVo> getFiles() {
        return files;
    }

    public void setFiles(List<ReconciliationFileSaveVo> files) {
        this.files = files;
    }

    public List<ReconciliationRowSaveVO> getRows() {
        return rows;
    }

    public void setRows(List<ReconciliationRowSaveVO> rows) {
        this.rows = rows;
    }
}
